<?php
namespace app\index\controller;

use think\Db;

class Lst extends Base
{
    public function index()
    {
        $cate = Db::name('cate')->field('catename')->find(input('id'));
        $catename = $cate['catename'];
        $this->assign('catename', $catename);

        $status = db('article')->order('id')->where('cateid', '=', input('id'))->paginate(2);
        $this->assign('status', $status);
        return $this->fetch('lst');
    }
}
